home *** CD-ROM | disk | FTP | other *** search
/ New Perspectives on Computer Concepts / New Perspectives on Computer Concepts.iso / np2010c / page766.pag < prev    next >
Portable Network Graphic  |  2008-10-02  |  42KB  |  817x1045  |  8-bit (256 colors)
Labels: crt screen | hakham | monitor | sky
OCR: 698 SECTION CHAPTER 1.2 Can computer autom atically repeat series of instruc- tions repetition control structure directs the computer to repeat one or more instructions until: certain condition met. The section code that repeats is usually referred to as loop or iteration. Some of the most fre- quently used repetition commands are FOR... .NEXT, DO. .WHILE DO .UNTIL and WHILE WEND The keyword FOR DO or WHILE marks the beginning of a loop. The key- word NEXT UNTIL or WEND (which means while ends) marks the end of a loop. The following simple BASIC program uses FOR .NEXT command to print message three times: For Print "There no place like home Next End Follow the path of program execution in Figure 12-28 to see how com- FIGURE 12.28 puter executes series of commands in a repetition structure ...